package com.example.demo.redis;

import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Configuration;

//redis配置类，用来配置.yml里面对应的redis的相关信息
@Configuration
@ConfigurationProperties(prefix = "redis")
@Data
public class RedisConfig {
    private String host;
    private Integer port;
    private Integer timeout;
    private Integer poolMaxTotal;
    private Integer poolMaxIdle;
    private Integer poolMaxWait;
    //redis.host=127.0.0.1
    //redis.port=6379
    //redis.timeout=10
    //redis.poolMaxTotal=1000
    //redis.poolMaxIdle=500
    //redis.poolMaxWait=500
}
